package com.ruoyi.sys.personnel.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;

import java.util.Date;

/**
 * 人员管理/人员通行记录/进出记录
 */
@Data
@TableName("tb_pass")
public class TbPass {
    @TableId(value = "p_id",type = IdType.AUTO)
    private Integer pId;
    @TableField("u_id")
    private Integer uId;
    @TableField("p_type")
    private Integer pType;
    @TableField("p_card_number")
    private Integer pCardNumber;
    @TableField("p_mode")
    private Integer pMode;
    @TableField("p_date")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date pDate;
    @TableField("p_eg_id")
    private Integer pEgId;
    @TableField("p_photograph")
    private String pPhotograph;

    private User user;
    private TbEntranceGuard tbeg;
}



